import datetime

import django_filters
from django.contrib.auth.models import AnonymousUser
from django.db.models import Q
from loguru import logger
from rest_framework.filters import BaseFilterBackend

from apps.TabletInfo.models import TabletInfo

# 药品筛选
class TabletInfoFilter(django_filters.rest_framework.FilterSet):
    # 药品名称
    tblt_nm = django_filters.CharFilter(lookup_expr="icontains")
    id = django_filters.CharFilter(lookup_expr="exact")


    class Meta:
        model = TabletInfo
        fields = "__all__"
